/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package proyecto.modelo;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;

/**
 *
 * @author sistemas
 */
@Entity
@Table(name = "inv_stock")
@NamedQueries({
    @NamedQuery(name = "InvStock.findAll", query = "SELECT i FROM InvStock i"),
    @NamedQuery(name = "InvStock.findByStkalmacenId", query = "SELECT i FROM InvStock i WHERE i.stkalmacenId = :stkalmacenId"),
    @NamedQuery(name = "InvStock.findByARTICULOcodArticulo", query = "SELECT i FROM InvStock i WHERE i.aRTICULOcodArticulo = :aRTICULOcodArticulo"),
    @NamedQuery(name = "InvStock.findByStkstockFisico", query = "SELECT i FROM InvStock i WHERE i.stkstockFisico = :stkstockFisico"),
    @NamedQuery(name = "InvStock.findByStkstockDisponible", query = "SELECT i FROM InvStock i WHERE i.stkstockDisponible = :stkstockDisponible")})
public class InvStock implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @Basic(optional = false)
    @Column(name = "stk_almacenId")
    private Integer stkalmacenId;
    @Basic(optional = false)
    @Column(name = "ARTICULO_codArticulo")
    private int aRTICULOcodArticulo;
    @Column(name = "stk_stockFisico")
    private Integer stkstockFisico;
    @Column(name = "stk_stockDisponible")
    private Integer stkstockDisponible;

    public InvStock() {
    }

    public InvStock(Integer stkalmacenId) {
        this.stkalmacenId = stkalmacenId;
    }

    public InvStock(Integer stkalmacenId, int aRTICULOcodArticulo) {
        this.stkalmacenId = stkalmacenId;
        this.aRTICULOcodArticulo = aRTICULOcodArticulo;
    }

    public Integer getStkalmacenId() {
        return stkalmacenId;
    }

    public void setStkalmacenId(Integer stkalmacenId) {
        this.stkalmacenId = stkalmacenId;
    }

    public int getARTICULOcodArticulo() {
        return aRTICULOcodArticulo;
    }

    public void setARTICULOcodArticulo(int aRTICULOcodArticulo) {
        this.aRTICULOcodArticulo = aRTICULOcodArticulo;
    }

    public Integer getStkstockFisico() {
        return stkstockFisico;
    }

    public void setStkstockFisico(Integer stkstockFisico) {
        this.stkstockFisico = stkstockFisico;
    }

    public Integer getStkstockDisponible() {
        return stkstockDisponible;
    }

    public void setStkstockDisponible(Integer stkstockDisponible) {
        this.stkstockDisponible = stkstockDisponible;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (stkalmacenId != null ? stkalmacenId.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof InvStock)) {
            return false;
        }
        InvStock other = (InvStock) object;
        if ((this.stkalmacenId == null && other.stkalmacenId != null) || (this.stkalmacenId != null && !this.stkalmacenId.equals(other.stkalmacenId))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "proyecto.modelo.InvStock[stkalmacenId=" + stkalmacenId + "]";
    }

}
